package com.wiscamp.ninechapters.common.rest;

import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 分页器
 *
 * @author yifeng
 */
@Data
// @Entity
@EqualsAndHashCode
public class Pagination<T> {
    private int page;

    private int perpage;

    private int pages;

    private int total;

    private T query;

    public Pagination() {
    }

    public Pagination(int page, int perpage, int pages, int total, T query) {
        this.page = page;
        this.perpage = perpage;
        this.pages = pages;
        this.total = total;
        this.query = query;
    }
}
